#include "pch.h"
#include <iostream>
#include <string>

using  namespace std;

struct StudentInformation
{
	int StudentNo;
	string StudentName;
};

void input(string& SchoolName, string& ClassName, StudentInformation Student[20])
{
	cout << "请输入学校名字！" << endl;
	cin >> SchoolName;
	cout << "请输入班级名字！" << endl;
	cin >> ClassName;
	cout << "请输入20名学生的学号和姓名！" << endl;
	for (int i = 0;i < 20;i++)
	{
		cin >> Student[i].StudentNo >> Student[i].StudentName;
	}
}

void output(string SchoolName, string ClassName)
{
	cout << "学校名称:" << SchoolName << endl;
	cout << "班级名称:" << ClassName << endl;
}

void output(StudentInformation Student[20])
{
	for (int i = 0;i < 20;i++)
	{
		cout << "学号：" << Student[i].StudentNo << "    " << "姓名：" << Student[i].StudentName << endl;
	}
}

int main()
{
	string SchoolName, ClassName;
	StudentInformation Student[20];
	input(SchoolName, ClassName, Student);
	output(SchoolName, ClassName);
	output(Student);
	return 0;
}